package com.jyhz.model.pojo;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.*;
import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.List;

/**
 * @author:谢君臣
 * @Date:2021/6/27-19:33
 * @version:1.0
 * @function:
 */
@Setter
@Getter
@AllArgsConstructor
@NoArgsConstructor
@ToString
@Component
@TableName("person")
public class Person {
    private Long id;
    private String account;
    @TableField("name") // 数据库表字段名称一样处理方式
    private String username;
    @TableField("pwd")
    private String password;
    @TableField(exist = false) // 数据库表中不存在的字段处理方式
    private String birthday;
    private String mobile;
    @TableField(exist = false)
    private Dept dept;
    @TableField(exist = false)
    private School school;
    @TableField(exist = false)
    private List<Role> roles;

}
